package org.electrode.task;

import org.electrode.common.Variable;

public class VariableTransfer extends PeriodicTask {
	final Variable target;
	final Variable source;

	public VariableTransfer(Variable target, Variable source) {
		this.target = target;
		this.source = source;
	}

	public boolean doWork() {
		target.set(source.get());
		return true;
	}

	public PeriodicTask copy() {
		return new VariableTransfer(target, source);
	}

}
